<%--
  Created by IntelliJ IDEA.
  User: aaa
  Date: 2024/6/22
  Time: 16:30
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>学生管理系统</title>
</head>
<style>
    .top {
        border: black solid 5px;
    }

    .left {
        width: 200px;
        height: 270px;
        border: black solid 5px;
    }

    .left input {
        width: 100%;
        height: 50px;
        margin-left: 0;
        color: white;
        font-family: Arial;
        font-size: 20px;
        background-color: lightskyblue;
    }


</style>
<body>
<div class="top">
    <%--主页面的标题--%>
    <table width="100%" align="center">
        <tr>
            <td><img src="images/title.png" width="1400px" height="150px"></td>
        </tr>
    </table>
</div>
<div class="userMessage">
    <table border="0">
        <tr>
            <td class="userName">当前用户 ${session_newUser.getUserName()}  &nbsp;&nbsp;<%--<a href="#">修改密码</a></td>--%>
        </tr>
    </table>
</div>
<div class="left">
    <c:if test="${session_newUser.getUserIdentify()==0}">
        <table width="100%">
            <tr>
                <td><a href="MainPageServlet?action=index"><input type="button" value="查看首页"></a></td>
            </tr>
            <tr>
                <td><a href="StudentServlet?action=list"><input type="button" value="选择老师"></a></td>
            </tr>
            <tr>
                <td><a href="StudentServlet?action=goMyTeacher"><input type="button" value="我的老师"></a></td>
            </tr>
            <tr>
                <td><a href="MainPageServlet?action=goMyDetail"><input type="button" value="我的信息"></a></td>
            </tr>
            <tr>
                <td><a href="OutLoginServlet"><input type="button" value="退出系统"></a></td>
            </tr>
        </table>
    </c:if>
    <c:if test="${session_newUser.getUserIdentify()==1}">
        <table width="100%">
            <tr>
                <td><a href="MainPageServlet?action=index"><input type="button" value="查看首页"></a></td>
            </tr>
            <tr>
                <td><a href="TeacherServlet?action=studentList"><input type="button" value="学生管理"></a></td>
            </tr>
            <tr>
                <td><a href="TeacherServlet?action=goMyTask"><input type="button" value="任务管理"></a></td>
            </tr>
            <tr>
                <td><a href="TeacherServlet?action=goAddTask"><input type="button" value="添加任务"></a></td>
            </tr>
            <tr>
                <td><a href="MainPageServlet?action=goMyDetail"><input type="button" value="我的信息"></a></td>
            </tr>
            <tr>
                <td><a href="OutLoginServlet"><input type="button" value="退出系统"></a></td>
            </tr>
        </table>
    </c:if>
    <c:if test="${session_newUser.getUserIdentify()==2}">
        <table width="100%">
            <tr>
                <td><a href="MainPageServlet?action=index"><input type="button" value="查看首页"></a></td>
            </tr>
            <tr>
                <td><a href="ManagerServlet?action=allUserList"><input type="button" value="人员管理"></a></td>
            </tr>
            <tr>
                <td><a href="ManagerServlet?action=goAddPerson"><input type="button" value="人员添加"></a></td>
            </tr>
            <tr>
                <td><a href="MainPageServlet?action=goMyDetail"><input type="button" value="我的信息"></a></td>
            </tr>
            <tr>
                <td><a href="OutLoginServlet"><input type="button" value="退出系统"></a></td>
            </tr>
        </table>
    </c:if>
</div>
<div class="mainRight">
    <%--三元运算符判断要跳转的页面,如果mainPage的值为null,则跳转blank.jsp.否则就是它自己的值--%>
    <jsp:include page="${mainRight=null?'blank.jsp':mainRight}"></jsp:include>
</div>
</body>
</html>
